const express = require('express');

const app = express();

const mw = function(req, res, next) {
    console.log('这是消息中间件');
    next();
}

app.get('/', (req, res) => {
    res.send('Home Page');
})

app.get('/user', mw, (req, res) => {
    res.send('User Page');
})

app.listen('80', function() {
    console.log('http://127.0.0.1');
})